package com.qiyu.controller.front;

import com.qiyu.common.R;
import com.qiyu.constant.AuthRole;
import com.qiyu.model.response.front.HomeRes;
import com.qiyu.service.HomeService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@Api(tags = "首页展示")
@Slf4j
@RequestMapping(AuthRole.DISPLAY + "/home")
public class FrontHomeController {

    @Autowired
    private HomeService homeService;
    @GetMapping("/queryHome")
    @ApiOperation("首页查询")
    public R<HomeRes> queryHome(){
        return R.ok(homeService.queryHome());
    }
}
